{{ define "main" }}

<div id="page-404">
  <div class="text">
      {{ with .Site.Params.title404 }}
          <h1>{{ . }}</h1>
      {{ else }}
          <h1>{{ i18n "404title" }}</h1>
      {{ end }}

      {{ with .Site.Params.subtitle404 }}
          <div>{{ . }}</div>
      {{ else }}
          <div>{{ i18n "404subtitle" }}</div>
      {{ end }}
    </div>

  {{ with .Site.Params.readMore }}
      <h2 class="read-more">{{ . }}</h2> 
  {{ else }}
      <h2 class="read-more">{{ i18n "readMore" }}</h2> 
  {{ end }}

  


    {{ $pages := .Site.RegularPages }}
    {{ $paginator := .Paginate ($pages) }}
    {{ range $paginator.Pages }}
        {{ $title := .Title }}
        {{ $date := dateFormat "Jan 2, 2006" .Date }}
        <section class="item">
          <div>
            <h1 class="title"><a href='{{ .RelPermalink }}'>{{ $title }}</a></h1>   
            <div class="date">{{ $date }}</div>
          </div>
        </section>
    {{ end }}
</div>
{{ end }}
